package com.finance.cooperate.dao.entity.primary;

import com.finance.cooperate.dao.support.pojo.BaseAutomaticSimpleVO;
import lombok.Data;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @ClassName AppApply
 * @Description 申请件表
 * @Author shen
 * @Date 2023/8/5 22:03
 * @Modify ...
 */
@Entity
@Table(name = "app_apply")
@Data
public class Apply extends BaseAutomaticSimpleVO {

    private static final long serialVersionUID = -7330550891537460400L;


    // ID
    @Id
    @Column(name = "id")
    private String id;

    // 选择的金额
    @Column(name = "select_amount")
    private BigDecimal selectAmount;

    // 选择的期限
    @Column(name = "select_time_limit")
    private Integer selectTimeLimit;

    // 授信后的额度
    @Column(name = "after_amount_start")
    private BigDecimal afterAmountStart;

    // 授信后的额度
    @Column(name = "after_amount_end")
    private BigDecimal afterAmountEnd;

    // 退回原因
    @Column(name = "return_reason")
    private String returnReason;

    // 授信状态 0未授信，1审核成功、-1审核失败，2审核中，3被退回  4放款拒绝
    @Column(name = "state")
    private Integer state;

    // 是否初审 0不是 1是
    @Column(name = "people_state")
    private Integer peopleState;

    // 初审人
    @Column(name = "trial_user")
    private String trialUser;

    // 是否终身  0 不是  1是
    @Column(name = "final_state")
    private Integer finalState;

    // 终审人
    @Column(name = "final_user")
    private String finalUser;

    // 人工审核状态   1通过  -1拒绝
    @Column(name = "artificial_state")
    private Integer artificialState;

    // 风控状态 1 通过  -1解决   3退回
    @Column(name = "risk_state")
    private Integer riskState;

    // 用户id
    @Column(name = "user_id")
    private String userId;

    // 0 安卓 1 ios
    @Column(name = "is_ios")
    private Integer isIos;

    // 可再申请时间
    @Column(name = "toapply_time")
    private Date toapplyTime;

    // 审核通过时间
    @Column(name = "through_time")
    private Date throughTime;

    // 审核提交时间
    @Column(name = "submit_time")
    private Date submitTime;

    // 风控审核时间
    @Column(name = "risk_time")
    private Date riskTime;

    // 初审时间
    @Column(name = "trial_time")
    private Date trialTime;

    // 终审时间
    @Column(name = "final_time")
    private Date finalTime;

    // ip 地址
    @Column(name = "ip")
    private String ip;

    // ip对应国家
    @Column(name = "ipcountries")
    private String ipcountries;

    // ip对应省
    @Column(name = "ipprovince")
    private String ipprovince;

    // ip对应城市
    @Column(name = "ipcity")
    private String ipcity;

    // 应用包名
    @Column(name = "package_name")
    private String packageName;

    // -1 查询异常， 0验证错误，1 验证正确  ，2找不到该人(身份证验证结果)
    @Column(name = "identity_check")
    private Integer identityCheck;

    // app_user_bank id
    @Column(name = "user_bank_id")
    private String userBankId;

    // 是否借款  0未借款  1已借款
    @Column(name = "is_borrowing")
    private Integer isBorrowing;

    // 进度  0  1（个人信息提交）  2（工作信息提交）  3（联系人提交）  4（身份信息提交）
    @Column(name = "progress")
    private Integer progress;

    // 用户类型
    @Column(name = "user_type")
    private String userType;

    // 广告公司id
    @Column(name = "campaign_id")
    private String campaignId;

}
